package com.jichangxiu.server.platform.entity.map;

import com.jichangxiu.server.platform.entity.dto.PlatformDictDataQueryDto;
import com.jichangxiu.server.platform.entity.po.PlatformDictData;
import com.jichangxiu.server.platform.entity.vo.PlatformDictDataAddVo;
import com.jichangxiu.server.platform.entity.vo.PlatformDictDataEditVo;
import com.jichangxiu.server.platform.entity.vo.PlatformDictDataQueryVo;
import org.mapstruct.Builder;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * PlatformDictDataBasic:
 *
 * @author Jcx
 * @create 2023-03-19 8:41
 */
@Mapper(builder = @Builder(disableBuilder = true))
public interface PlatformDictDataBasic {

    public PlatformDictDataBasic INSTANCE = Mappers.getMapper(PlatformDictDataBasic.class);

    /**
     * 转换 PlatformDictType
     *
     * @param platformDictDataAddVo 视图对象
     * @return 数据库对象
     */
    public PlatformDictData toPlatformDictData(PlatformDictDataAddVo platformDictDataAddVo);

    /**
     * 转换 PlatformDictType
     *
     * @param platformDictDataEditVo 视图对象
     * @return 数据库对象
     */
    public PlatformDictData toPlatformDictData(PlatformDictDataEditVo platformDictDataEditVo);

    /**
     * 转换 PlatformDictType
     *
     * @param platformDictDataQueryVo 视图对象
     * @return 数据库对象
     */
    public PlatformDictData toPlatformDictData(PlatformDictDataQueryVo platformDictDataQueryVo);

    /**
     * 转换 PlatformDictTypeQueryDto
     *
     * @param platformDictData 数据库对象
     * @return 传输对象
     */
    public PlatformDictDataQueryDto toPlatformDictDataQueryDto(PlatformDictData platformDictData);

    /**
     * 转换 PlatformDictTypeQueryDto 列表
     *
     * @param platformDictDataList 数据库对象列表
     * @return 传输对象列表
     */
    public List<PlatformDictDataQueryDto> toPlatformDictDataQueryDtoList(List<PlatformDictData> platformDictDataList);

}
